<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
  xmlns:h="http://java.sun.com/jsf/html"
  xmlns:ui="http://java.sun.com/jsf/facelets">
  <head>
  </head>
  <body>
    <ui:composition template="/WEB-INF/templates/main.xhtml">
      <ui:define name="titoloSezione">Autenticazione</ui:define>
      <ui:define name="titoloSottoSezione">Login</ui:define>
      
      <ui:define name="corpo">
        <h1>Benvenuto in BiPoD !</h1>
        
        <fieldset style="width: 300px">
          <legend class="legend">Informazioni di Login</legend>
          <table class="plainText" style="width: 300px">
            <h:form>
              <tr>
                <td style="width: 50%">Nome Utente:</td>
                <td style="width: 50%"><h:inputText id="nomeUtente" value="#{mainBean.login.nomeUtente}" required="true"/></td>
                <td><h:message for="nomeUtente" class="warnMessage"/></td>
              </tr>
              <tr>
                <td>Password:</td>
                <td><h:inputSecret id="password" value="#{mainBean.login.password}" required="true"/></td>
                <td><h:message for="password" class="warnMessage"/></td>
              </tr>
              <tr>
                <td colspan="2">
                  <h:commandButton value="Login" action="#{mainBean.login.login}" style="width: 100%"/>
                </td>
                <td></td>
              </tr>
            </h:form>
            <h:form>
              <tr>
                <td colspan="2" style="text-align: center">
                  <h:commandLink value="Recupera dati di accesso" action="pages/recupero-dati"/>
                </td>
                <td></td>
              </tr>
            </h:form>
          </table>
        </fieldset>
        
      </ui:define>
    </ui:composition>
  </body>
</html>